package com.dhemery.mack.model.tests;


import static org.junit.Assert.*;

import org.junit.Test;

import com.dhemery.mack.model.Item;

public class ItemTests {
	@Test
	public void itemRemembersGivenName() {
		String itemName = "a name";
		
		Item item = new Item(itemName);
		
		assertEquals(itemName, item.getName());
	}

	@Test
	public void remembersSetName() {
		Item item = new Item("");
		String newName = "new name";
		
		item.setName(newName);
		
		assertEquals(newName, item.getName());
	}

	@Test
	public void newItemHasEmptyDescription() {
		Item item = new Item("");
		
		assertEquals("", item.getDescription());
	}

	@Test
	public void remembersSetDescription() {
		Item item = new Item("");
		String newDescription = "new description";
		item.setDescription(newDescription );
		assertEquals(newDescription, item.getDescription());
	}
}
